include $(top_srcdir)/common.mk

AM_CPPFLAGS += -I$(top_srcdir)/common  -I$(top_srcdir)/lib \
           -I$(top_srcdir)/api -I./

sbin_PROGRAMS = jm

jm_SOURCES = communicate.c handlefile.c handlejob.c jm.main.c \
             handlepolicy.c handlesocket.c handlesignal.c handlexdr.c \
	     collector.c internal.c lockfile.c handletask.c handlecgroup.c \
		 linux.c

jm_LDADD =  ../api/.libs/libqpapi.a ../lib/.libs/libqpbase.a ../common/.libs/libtools.a \
            -lm -lnsl -lyaml -ltcl

if HWLOC
jm_LDADD += -lhwloc -lnuma
AM_CPPFLAGS += -Dhwloc
endif

if ENABLE_TIRPC
jm_LDADD += -ltirpc
endif
